//
//  YongHuXieYiViewController.m
//  EJLX
//
//  Created by xufei on 15/12/15.
//  Copyright © 2015年 江苏一键联信息科技有限公司. All rights reserved.
//

#import "YongHuXieYiViewController.h"

@interface YongHuXieYiViewController ()

@end

@implementation YongHuXieYiViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view from its nib.
    self.view.backgroundColor=[UIColor whiteColor];
    UIView*view=[[UIView alloc]initWithFrame:CGRectMake(0, 20,WIDE, 44)];
    view.backgroundColor=RGB_COLOR(0x00c49f);
    [self.view addSubview:view];
    UILabel*label=[[UILabel alloc]initWithFrame:CGRectMake(WIDE/2-35, 10, 70, 24)];
    label.text=@"用户协议";
    label.textAlignment=NSTextAlignmentCenter;
    label.textColor=[UIColor whiteColor];
    [view addSubview:label];
    UIButton*but1=[[UIButton alloc]initWithFrame:CGRectMake(10,7,30,30)];
    [but1 setImage:[UIImage imageNamed:@"返回箭头"] forState:UIControlStateNormal];
    [but1 addTarget:self action:@selector(butClick) forControlEvents:UIControlEventTouchUpInside];
    [view addSubview:but1];
    
    UIWebView*web=[[UIWebView alloc]init];
    web.frame=CGRectMake(0, 64, WIDE, HEIGHT-64);
    
    NSURL*URL=[NSURL URLWithString:@"http://121.42.211.76:8080//comm/user_agreement"];
    NSURLRequest*request=[NSURLRequest requestWithURL:URL];
    [web loadRequest:request];
    web.scalesPageToFit=YES;
    [self.view addSubview:web];
    
}
-(void)butClick
{
    [self.navigationController popViewControllerAnimated:YES];
}



- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
